Using data from 'https://raw.githubusercontent.com/mengluchu/uncertainty/master/data_vis_exp/DENL17_uc.csv'
(optional) further read: Global Spatial Autocorrelation
import geopandas as gpd
import pandas as pd
import numpy as np
from matplotlib import pyplot
import math # yay, for plotting ;)
from mpl_toolkits.axes_grid1.axes_divider import make_axes_locatable # more sophisticated messing
# with legends
# local dataset
spreadurl = '../raw.githubusercontent.com/mengluchu/uncertainty/master/data_vis_exp/DENL17_uc.csv'
# load dataset
dataset_pd = pd.read_csv(spreadurl)
To decide on which variable to use.
# inspect dataset
print("Listing attributes:\t", *dir(dataset_pd), sep = "\n\t" )
display( type(dataset_pd) )
Listing attributes: AirQualityStation AirQualityStationArea AirQualityStationType Altitude BuildingDistance Countrycode EquivalenceDemonstrated InletHeight KerbDistance Latitude Longitude MeasurementEquipment MeasurementType T X _AXIS_LEN _AXIS_ORDERS _AXIS_REVERSED _AXIS_TO_AXIS_NUMBER _HANDLED_TYPES __abs__ __add__ __and__ __annotations__ __array__ __array_priority__ __array_ufunc__ __array_wrap__ __bool__ __class__ __contains__ __copy__ __deepcopy__ __delattr__ __delitem__ __dict__ __dir__ __divmod__ __doc__ __eq__ __finalize__ __floordiv__ __format__ __ge__ __getattr__ __getattribute__ __getitem__ __getstate__ __gt__ __hash__ __iadd__ __iand__ __ifloordiv__ __imod__ __imul__ __init__ __init_subclass__ __invert__ __ior__ __ipow__ __isub__ __iter__ __itruediv__ __ixor__ __le__ __len__ __lt__ __matmul__ __mod__ __module__ __mul__ __ne__ __neg__ __new__ __nonzero__ __or__ __pos__ __pow__ __radd__ __rand__ __rdivmod__ __reduce__ __reduce_ex__ __repr__ __rfloordiv__ __rmatmul__ __rmod__ __rmul__ __ror__ __round__ __rpow__ __rsub__ __rtruediv__ __rxor__ __setattr__ __setitem__ __setstate__ __sizeof__ __str__ __sub__ __subclasshook__ __truediv__ __weakref__ __xor__ _accessors _accum_func _add_numeric_operations _agg_by_level _agg_examples_doc _agg_summary_and_see_also_doc _align_frame _align_series _arith_method _as_manager _attrs _box_col_values _can_fast_transpose _check_inplace_and_allows_duplicate_labels _check_inplace_setting _check_is_chained_assignment_possible _check_label_or_level_ambiguity _check_setitem_copy _clear_item_cache _clip_with_one_bound _clip_with_scalar _cmp_method _combine_frame _consolidate _consolidate_inplace _construct_axes_dict _construct_axes_from_arguments _construct_result _constructor _constructor_sliced _convert _count_level _data _dir_additions _dir_deletions _dispatch_frame_op _drop_axis _drop_labels_or_levels _ensure_valid_index _find_valid_index _flags _from_arrays _from_mgr _get_agg_axis _get_axis _get_axis_name _get_axis_number _get_axis_resolvers _get_block_manager_axis _get_bool_data _get_cleaned_column_resolvers _get_column_array _get_index_resolvers _get_item_cache _get_label_or_level_values _get_numeric_data _get_value _getitem_bool_array _getitem_multilevel _gotitem _hidden_attrs _indexed_same _info_axis _info_axis_name _info_axis_number _info_repr _init_mgr _inplace_method _internal_names _internal_names_set _is_copy _is_homogeneous_type _is_label_or_level_reference _is_label_reference _is_level_reference _is_mixed_type _is_view _iset_item _iset_item_mgr _iset_not_inplace _item_cache _iter_column_arrays _ixs _join_compat _logical_func _logical_method _maybe_cache_changed _maybe_update_cacher _metadata _mgr _min_count_stat_function _needs_reindex_multi _protect_consolidate _reduce _reindex_axes _reindex_columns _reindex_index _reindex_multi _reindex_with_indexers _replace_columnwise _repr_data_resource_ _repr_fits_horizontal_ _repr_fits_vertical_ _repr_html_ _repr_latex_ _reset_cache _reset_cacher _sanitize_column _series _set_axis _set_axis_name _set_axis_nocheck _set_is_copy _set_item _set_item_frame_value _set_item_mgr _set_value _setitem_array _setitem_frame _setitem_slice _slice _stat_axis _stat_axis_name _stat_axis_number _stat_function _stat_function_ddof _take_with_is_copy _to_dict_of_blocks _typ _update_inplace _validate_dtype _values _where abs add add_prefix add_suffix agg aggregate align all any append apply applymap asfreq asof assign astype at at_time attrs axes backfill between_time bfill bool boxplot clip columns combine combine_first compare convert_dtypes copy corr corrwith count cov cummax cummin cumprod cumsum describe diff div divide dot drop drop_duplicates droplevel dropna dtypes duplicated elevation empty eq equals eval ewm expanding explode ffill fillna filter first first_valid_index flags floordiv from_dict from_records ge get groupby gt head hist iat idxmax idxmin iloc index industry_100 industry_1000 industry_25 industry_300 industry_3000 industry_50 industry_500 industry_5000 infer_objects info insert interpolate isin isna isnull items iteritems iterrows itertuples join keys kurt kurtosis lasso10f_pre lasso_all_pre last last_valid_index le loc lookup lt mad mask max mean mean_value median melt memory_usage merge min mod mode mul multiply ndim ne nightlight_3150 nightlight_450 nightlight_4950 nightlight_900 nlargest notna notnull nsmallest nunique pad pct_change pipe pivot pivot_table plot pop population_1000 population_3000 population_5000 pow prod product quantile query radd radiation rank rdiv reindex reindex_like rename rename_axis reorder_levels replace resample reset_index rf10f_pre rf_all_pre rfloordiv rmod rmul road_class_1_100 road_class_1_1000 road_class_1_25 road_class_1_300 road_class_1_3000 road_class_1_50 road_class_1_500 road_class_1_5000 road_class_2_100 road_class_2_1000 road_class_2_25 road_class_2_300 road_class_2_3000 road_class_2_50 road_class_2_500 road_class_2_5000 road_class_3_100 road_class_3_1000 road_class_3_25 road_class_3_300 road_class_3_3000 road_class_3_50 road_class_3_500 road_class_3_5000 rolling round rpow rsub rtruediv sample select_dtypes sem set_axis set_flags set_geometry set_index shape shift size skew slice_shift sort_index sort_values squeeze stack std style sub subtract sum swapaxes swaplevel tail take temperature_2m_1 temperature_2m_10 temperature_2m_11 temperature_2m_12 temperature_2m_2 temperature_2m_3 temperature_2m_4 temperature_2m_5 temperature_2m_6 temperature_2m_7 temperature_2m_8 temperature_2m_9 to_clipboard to_csv to_dict to_excel to_feather to_gbq to_hdf to_html to_json to_latex to_markdown to_numpy to_parquet to_period to_pickle to_records to_sql to_stata to_string to_timestamp to_xarray to_xml transform transpose trop_mean_filt truediv truncate tz_convert tz_localize unstack update urbantype urbantype_chara value_counts values var where wind_speed_10m_1 wind_speed_10m_10 wind_speed_10m_11 wind_speed_10m_12 wind_speed_10m_2 wind_speed_10m_3 wind_speed_10m_4 wind_speed_10m_5 wind_speed_10m_6 wind_speed_10m_7 wind_speed_10m_8 wind_speed_10m_9 wkd_day_value wkd_night_value wnd_day_value wnd_night_value xgb10f_pre xgb_all_pre xs
pandas.core.frame.DataFrame
# check for duplicates using duplicated
# 'keep False' means: Mark all duplicates as True.
# ?? -_-
print("All duplicate rows:")
display( dataset_pd[dataset_pd.duplicated(keep=False)] )
print( "\nDuplicated values from e.g. nightlight_3150:" )
display( dataset_pd[ dataset_pd.duplicated("nightlight_3150", keep=False) ] )
print( "\nLocations should be unique. Duplicate locations:" ),
display(
dataset_pd[ dataset_pd.duplicated( ["Latitude", "Longitude"],
keep=False
)
]
)
All duplicate rows:
| Unnamed: 0 | X.1 | X | Longitude | Latitude | wkd_day_value | wnd_day_value | wkd_night_value | wnd_night_value | radiation | ... | BuildingDistance | KerbDistance | rf10f_pre | xgb10f_pre | lasso10f_pre | rf_all_pre | xgb_all_pre | lasso_all_pre | urbantype | urbantype_chara |
|---|
0 rows × 95 columns
Duplicated values from e.g. nightlight_3150:
| Unnamed: 0 | X.1 | X | Longitude | Latitude | wkd_day_value | wnd_day_value | wkd_night_value | wnd_night_value | radiation | ... | BuildingDistance | KerbDistance | rf10f_pre | xgb10f_pre | lasso10f_pre | rf_all_pre | xgb_all_pre | lasso_all_pre | urbantype | urbantype_chara | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 383 | 384 | 384 | 384 | 11.979056 | 51.496185 | 17.152831 | 12.022231 | 18.685666 | 15.742601 | 2.975865 | ... | -999 | -999 | 25.366037 | 28.561787 | 25.366037 | 21.864927 | 17.165314 | 25.527346 | 3 | urban |
| 384 | 385 | 385 | 385 | 11.981314 | 51.494756 | 54.889111 | 34.662143 | 35.587841 | 22.443055 | 2.975864 | ... | 5 | 1 | 35.722445 | 38.365921 | 35.722445 | 40.379401 | 42.713234 | 35.736941 | 3 | urban |
2 rows × 95 columns
Locations should be unique. Duplicate locations:
| Unnamed: 0 | X.1 | X | Longitude | Latitude | wkd_day_value | wnd_day_value | wkd_night_value | wnd_night_value | radiation | ... | BuildingDistance | KerbDistance | rf10f_pre | xgb10f_pre | lasso10f_pre | rf_all_pre | xgb_all_pre | lasso_all_pre | urbantype | urbantype_chara |
|---|
0 rows × 95 columns
Load the dataset as a geo referenced geopandas dataframe
## Fortunately we know the propper projection
dataset_gdf = gpd.GeoDataFrame( dataset_pd,
crs = "EPSG:4326",
geometry = gpd.points_from_xy( dataset_pd.Longitude,
dataset_pd.Latitude
)
)
Plotting could be achieved like this.
# background colours
fig_bgc="#cccccc" # of plotting area
axs_bgc="lightslategrey" # of area between the axes
# create figure
fig = pyplot.figure( figsize = ( 16, 9),
facecolor = fig_bgc
)
# directions are [left, bottom, width, height]
ax1 = fig.add_axes([-0.08, 0.2, 0.8, 0.8])
ax2 = fig.add_axes([0.5, 0.2, 0.8, 0.8])
ax1.set_facecolor(axs_bgc)
ax2.set_facecolor(axs_bgc)
# this is handy if we'd like to be more specific
# about where to place the legend
# https://matplotlib.org/stable/gallery/axes_grid1/demo_colorbar_with_axes_divider.html?highlight=axes_divider
#divider1 = make_axes_locatable( ax1 )
#cax1 = divider1.append_axes( "right", size="2%", pad=-0.3 )
dataset_gdf.plot( ax = ax1,
#cax = cax1,
column = "nightlight_3150",
categorical = False,
legend = True,
# the legend is a colorbar
# https://matplotlib.org/stable/api/_as_gen/matplotlib.pyplot.colorbar.html
legend_kwds={ 'label': "Night light",
# 'orientation': "vertical",
# 'bbox_to_anchor': [1, 1],
'location':'right',
'fraction':0.15,
'shrink': 1.0,
'pad': 0,
'anchor': (-1.0, 0.5),
'panchor': False
}
)
# get coordinates in reference to the whole figure
axbox = ax2.get_position()
dataset_gdf.plot( ax = ax2,
column = "urbantype_chara",
categorical = True,
legend = True,
# with categorical data it seems we're in a totally different object
# https://matplotlib.org/stable/api/legend_api.html
legend_kwds={ 'title': 'Urban type',
'ncol': dataset_gdf.urbantype_chara.nunique(),
'facecolor': axs_bgc,
'edgecolor': "black",
'labelcolor': "markerfacecolor", # yeah looks silly ;)
'markerscale': 1.8,
# 'frameon': False,
'shadow': False,
'mode': "expand",
'loc': "lower left",
# specifies the bbox (x, y, width, height):
'bbox_to_anchor': (0.0, -0.14, 1, -0.0),
'borderpad': 0.6,
'borderaxespad': 0
# useful when using "divide"
# 'bbox_to_anchor': ( axbox.x0+0.52, axbox.y0-0.05 ),
# 'bbox_transform': fig.transFigure
})
<Axes:>
Doesn't look nice although a grey background helps in differentiating hues, but anyway it gives an idea what we can do. And as we're trying to find an interesting data column, it would be nice to look at them im groups. Fortunately, we can collect columns starting with a certain string..
nightlight_list = [col for col in dataset_gdf.columns if col.startswith('night')]
for element in nightlight_list:
print(element)
nightlight_450 nightlight_4950 nightlight_3150 nightlight_900
We can also get a statistical overview of those columns, sorted alphabetically.
dataset_gdf.loc[:, dataset_gdf.columns.str.startswith('night', na=False) ].describe()
| nightlight_450 | nightlight_4950 | nightlight_3150 | nightlight_900 | |
|---|---|---|---|---|
| count | 482.000000 | 482.000000 | 482.000000 | 482.000000 |
| mean | 15.245239 | 9.044186 | 11.033635 | 14.686876 |
| std | 13.472012 | 10.162684 | 10.997232 | 12.831380 |
| min | 0.000000 | 0.000560 | 0.000000 | 0.000000 |
| 25% | 4.665090 | 1.953545 | 2.928990 | 4.425944 |
| 50% | 13.828376 | 5.969375 | 8.181555 | 13.257292 |
| 75% | 22.387954 | 12.523816 | 16.410417 | 21.301006 |
| max | 83.368286 | 108.899269 | 105.218941 | 72.906769 |
And it could be helpful to know the members of a categorical column, e.g. "urbantype_chara".
dataset_gdf.urbantype_chara.nunique()
3
Let's wrap this up into a function that takes the geopandas dataframe and a keyword for the columns we're interested in.
## Fortunately we know the propper projection
dataset_gdf = gpd.GeoDataFrame( dataset_pd,
crs = "EPSG:4326",
geometry = gpd.points_from_xy( dataset_pd.Longitude,
dataset_pd.Latitude
)
)
def plot_this( local_object, local_keyword ):
"""What am I doing here"""
# background colours
fig_bgc = "#cccccc" # Whole plot area
axs_bgc = "lightslategrey" # subplot area
lgd_bgc = "slategrey" # legend area
# get a list of matching column names
colnames_list = [col for col in local_object.columns if col.startswith( local_keyword )]
# can stop if there's nothing to plot
if ( len(colnames_list) < 1 ):
return "Found no matches."
# create figure
fig = pyplot.figure( figsize = ( 16, 6*math.ceil( len(colnames_list) /2)),
facecolor = fig_bgc)
fig.subplots_adjust( hspace=0.1, wspace=-0.2)
# for each column..
for element in colnames_list:
# seems one has to differ between
# categorical and numeric data
# in pyplot
if local_object.dtypes[ element ] != object:
# type is numeric, hopefully
ax = fig.add_subplot( math.ceil( len(colnames_list) /2), 2, colnames_list.index(element)+1)
ax.set_facecolor(axs_bgc)
divider = make_axes_locatable( ax ) # unused, otherwise -> cax
local_object.plot( ax = ax,
# cax = divider.append_axes( "right", size="4%", pad=-0.5),
column = element,
categorical = False,
legend = True,
#
legend_kwds={ 'label': element,
# 'orientation': "vertical",
'location': 'right',
# 'fraction': 0.032,
'shrink': 0.905, # this is always off by a bit
'pad': 0.01,
'anchor': ( 0, 0.5),
'panchor': False
}
)
else:
# type probably categorical
ax = fig.add_subplot( math.ceil( len(colnames_list) /2),
2,
colnames_list.index(element)+1)
axbox = ax.get_position() # unused now
ax.set_facecolor(axs_bgc)
local_object.plot( ax = ax,
column = element,
facecolor = axs_bgc,
categorical = True,
# legend_var='scale',
legend = True if ( local_object[element].nunique() < 8 ) else False,
legend_kwds={
'ncol': min(3,local_object[element].nunique()),
'labelcolor': "white",
'title': "[ %s ]" % element,
'facecolor': lgd_bgc,
'edgecolor': "black",
'framealpha': 1,
'loc': 'upper center',
'bbox_to_anchor': ( 0.50, 1.1 ),
# 'bbox_to_anchor': ( axbox.x0+0.52, axbox.y0-0.05 ),
# 'bbox_transform': fig.transFigure
})
# pyplot.tight_layout()
pyplot.show()
display(
local_object.loc[:, local_object.columns.str.startswith( local_keyword, na=False) ].describe()
)
# return colnames_list
And plot along..
plot_this( dataset_gdf, "road")
| road_class_1_1000 | road_class_1_100 | road_class_1_25 | road_class_1_3000 | road_class_1_300 | road_class_1_5000 | road_class_1_500 | road_class_1_50 | road_class_2_1000 | road_class_2_100 | ... | road_class_2_500 | road_class_2_50 | road_class_3_1000 | road_class_3_100 | road_class_3_25 | road_class_3_3000 | road_class_3_300 | road_class_3_5000 | road_class_3_500 | road_class_3_50 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| count | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | ... | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 |
| mean | 1212.001476 | 12.295357 | 1.529753 | 12302.269079 | 101.676785 | 34352.880076 | 280.871975 | 3.874495 | 2231.118530 | 68.942846 | ... | 732.897073 | 28.610143 | 22133.352695 | 272.058826 | 32.639911 | 136692.065990 | 2314.033584 | 304244.123651 | 6247.359697 | 79.579393 |
| std | 2705.754172 | 73.109976 | 12.240787 | 13434.904610 | 403.926782 | 30123.308468 | 911.739711 | 28.728664 | 2656.942121 | 145.932769 | ... | 1087.161665 | 64.267149 | 13329.888215 | 236.379343 | 41.931537 | 83339.859642 | 1547.899665 | 186246.744040 | 3891.777537 | 86.872853 |
| min | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | ... | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 2934.527344 | 0.000000 | 0.000000 |
| 25% | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | 7751.374756 | 0.000000 | 0.000000 | 0.000000 | 0.000000 | ... | 0.000000 | 0.000000 | 10593.276612 | 29.281440 | 0.000000 | 70823.226562 | 930.852341 | 153694.312500 | 2949.663025 | 0.000000 |
| 50% | 0.000000 | 0.000000 | 0.000000 | 9506.948731 | 0.000000 | 29043.455078 | 0.000000 | 0.000000 | 1656.107727 | 0.000000 | ... | 0.000000 | 0.000000 | 23979.541992 | 257.587921 | 11.771501 | 134524.296875 | 2447.691162 | 285826.734375 | 6821.603515 | 63.218850 |
| 75% | 191.151607 | 0.000000 | 0.000000 | 19608.458496 | 0.000000 | 53922.870117 | 0.000000 | 0.000000 | 3915.911011 | 0.000000 | ... | 1382.680206 | 0.000000 | 32305.357910 | 406.096954 | 55.440739 | 193091.816406 | 3403.388611 | 424710.835938 | 8895.045411 | 126.067910 |
| max | 22668.818359 | 982.912109 | 154.998383 | 63091.585938 | 3659.216797 | 138998.265625 | 8483.940430 | 380.213654 | 14778.764648 | 735.144348 | ... | 5596.074219 | 294.457245 | 60375.496094 | 1088.154419 | 215.184708 | 444277.312500 | 7239.326660 | 953284.375000 | 18688.234375 | 438.252808 |
8 rows × 24 columns
plot_this( dataset_gdf, "Air")
| AirQualityStation | AirQualityStationType | AirQualityStationArea | |
|---|---|---|---|
| count | 482 | 482 | 482 |
| unique | 482 | 3 | 6 |
| top | STA-NL00318 | background | urban |
| freq | 1 | 295 | 289 |
So when .describe() only has categorical data, it suddenly displays those.
plot_this( dataset_gdf, "popul")
| population_1000 | population_3000 | population_5000 | |
|---|---|---|---|
| count | 482.000000 | 482.000000 | 482.000000 |
| mean | 6149.919575 | 41495.331104 | 94124.200708 |
| std | 4504.243782 | 35000.951753 | 88325.729436 |
| min | 0.000000 | 0.000000 | 552.417297 |
| 25% | 2219.177917 | 11524.904785 | 23243.484375 |
| 50% | 5981.528320 | 33830.275390 | 69034.738281 |
| 75% | 8995.891602 | 61942.635742 | 141487.503906 |
| max | 20335.248047 | 165796.593750 | 431906.093750 |
The size of the legend bounces, unfortunately. And Munich seems to outrule Berlin if displayed this way, will have to look into pyplot's use of symbols at some time.
plot_this( dataset_gdf, "industry")
| industry_1000 | industry_100 | industry_25 | industry_3000 | industry_300 | industry_5000 | industry_500 | industry_50 | |
|---|---|---|---|---|---|---|---|---|
| count | 482.000000 | 482.000000 | 482.000000 | 4.820000e+02 | 482.000000 | 4.820000e+02 | 482.000000 | 482.000000 |
| mean | 72139.605809 | 562.904564 | 57.665975 | 6.691105e+05 | 5116.400415 | 1.573677e+06 | 15579.865145 | 146.016598 |
| std | 139559.476816 | 2148.739070 | 242.876470 | 7.654970e+05 | 15060.527974 | 1.597702e+06 | 38782.751942 | 608.610773 |
| min | 0.000000 | 0.000000 | 0.000000 | 0.000000e+00 | 0.000000 | 0.000000e+00 | 0.000000 | 0.000000 |
| 25% | 0.000000 | 0.000000 | 0.000000 | 1.165988e+05 | 0.000000 | 4.023262e+05 | 0.000000 | 0.000000 |
| 50% | 11857.500000 | 0.000000 | 0.000000 | 4.415325e+05 | 0.000000 | 1.070362e+06 | 0.000000 | 0.000000 |
| 75% | 73440.000000 | 0.000000 | 0.000000 | 8.779650e+05 | 0.000000 | 2.171325e+06 | 9945.000000 | 0.000000 |
| max | 942735.000000 | 12495.000000 | 1275.000000 | 5.374380e+06 | 95880.000000 | 9.543120e+06 | 263160.000000 | 3315.000000 |
Industry_buffer is industrial area in different buffer rings, according to the source. TODO: Could be helpful to rename the buffer size to a four digit zero filled one, so the sorting and display of the plots becomes easier to understand.
plot_this( dataset_gdf, "wind_speed")
| wind_speed_10m_10 | wind_speed_10m_11 | wind_speed_10m_12 | wind_speed_10m_1 | wind_speed_10m_2 | wind_speed_10m_3 | wind_speed_10m_4 | wind_speed_10m_5 | wind_speed_10m_6 | wind_speed_10m_7 | wind_speed_10m_8 | wind_speed_10m_9 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| count | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 |
| mean | 3.657821 | 3.109849 | 3.695641 | 2.832647 | 3.396075 | 3.225519 | 2.954213 | 2.566703 | 3.003814 | 2.684772 | 2.510066 | 2.703582 |
| std | 1.014640 | 0.709750 | 0.821321 | 0.582540 | 0.852448 | 0.611392 | 0.701939 | 0.644373 | 0.727757 | 0.522073 | 0.600255 | 0.660366 |
| min | 1.136411 | 1.089057 | 1.248912 | 1.224902 | 1.105154 | 1.207697 | 1.108624 | 1.026124 | 1.021296 | 1.017121 | 0.875391 | 0.900630 |
| 25% | 2.886343 | 2.634187 | 3.157069 | 2.498561 | 2.862472 | 2.875859 | 2.399894 | 2.040184 | 2.458429 | 2.388771 | 2.101352 | 2.252375 |
| 50% | 3.649896 | 3.050460 | 3.634281 | 2.712368 | 3.238783 | 3.017025 | 2.866309 | 2.473387 | 2.902449 | 2.519323 | 2.463091 | 2.609148 |
| 75% | 3.973181 | 3.256055 | 3.934323 | 2.959297 | 3.685236 | 3.494962 | 3.329137 | 2.826228 | 3.264398 | 2.814551 | 2.727328 | 2.968780 |
| max | 7.854434 | 6.409105 | 7.108194 | 5.553333 | 7.063876 | 5.776276 | 5.886435 | 5.088363 | 5.799502 | 5.103355 | 4.864278 | 5.200004 |
These are very interesting!
plot_this( dataset_gdf, "temperature") # the number at the end is the month probably
| temperature_2m_10 | temperature_2m_11 | temperature_2m_12 | temperature_2m_1 | temperature_2m_2 | temperature_2m_3 | temperature_2m_4 | temperature_2m_5 | temperature_2m_6 | temperature_2m_7 | temperature_2m_8 | temperature_2m_9 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| count | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 | 482.000000 |
| mean | 11.990885 | 5.761023 | 3.095809 | -1.387652 | 3.403419 | 7.362716 | 7.820535 | 14.348214 | 18.277144 | 18.500820 | 18.385267 | 13.570848 |
| std | 1.187434 | 1.351124 | 1.531936 | 2.148167 | 1.414550 | 1.021405 | 0.906120 | 0.893466 | 1.099114 | 1.067688 | 0.939518 | 0.979193 |
| min | 5.784004 | -1.790898 | -6.633573 | -9.640343 | -2.401028 | 1.806271 | 1.705093 | 8.024415 | 13.388656 | 13.215975 | 14.189127 | 7.040077 |
| 25% | 11.266233 | 4.993205 | 2.347079 | -2.769608 | 2.425319 | 6.750848 | 7.387220 | 13.849962 | 17.516466 | 17.886613 | 17.661992 | 13.024728 |
| 50% | 12.019321 | 5.914032 | 3.360650 | -1.325603 | 3.255829 | 7.341378 | 7.983811 | 14.440387 | 18.426450 | 18.563983 | 18.319804 | 13.921696 |
| 75% | 12.756115 | 6.467558 | 4.004737 | 0.184844 | 4.759366 | 8.154031 | 8.426521 | 14.971505 | 19.066098 | 19.125787 | 19.097140 | 14.221741 |
| max | 14.187791 | 8.769836 | 5.881670 | 2.796631 | 6.037295 | 9.130181 | 9.701292 | 16.174713 | 20.879230 | 21.351744 | 20.931746 | 14.942817 |
plot_this( dataset_gdf, "night")
| nightlight_450 | nightlight_4950 | nightlight_3150 | nightlight_900 | |
|---|---|---|---|---|
| count | 482.000000 | 482.000000 | 482.000000 | 482.000000 |
| mean | 15.245239 | 9.044186 | 11.033635 | 14.686876 |
| std | 13.472012 | 10.162684 | 10.997232 | 12.831380 |
| min | 0.000000 | 0.000560 | 0.000000 | 0.000000 |
| 25% | 4.665090 | 1.953545 | 2.928990 | 4.425944 |
| 50% | 13.828376 | 5.969375 | 8.181555 | 13.257292 |
| 75% | 22.387954 | 12.523816 | 16.410417 | 21.301006 |
| max | 83.368286 | 108.899269 | 105.218941 | 72.906769 |
Also nightlight_450 and nightlight_900 look like good candidates.
plot_this( dataset_gdf, "urbantype")
| urbantype | |
|---|---|
| count | 482.000000 |
| mean | 2.406639 |
| std | 0.784860 |
| min | 1.000000 |
| 25% | 2.000000 |
| 50% | 3.000000 |
| 75% | 3.000000 |
| max | 3.000000 |
Something seems to get cached when plotting, at least on a notebook. Will have to find a reset-those-values function some time.
import mapclassify # for classification
import contextily as cx # for geographical context.
Ok now let's quickly look for a basemap.
cx.providers
New OneMap | Map data © contributors, Singapore Land Authority
New OneMap | Map data © contributors, Singapore Land Authority
New OneMap | Map data © contributors, Singapore Land Authority
New OneMap | Map data © contributors, Singapore Land Authority
New OneMap | Map data © contributors, Singapore Land Authority# display(cx.providers["JusticeMap"]) # just US I guess, no justice for Germany
# display(cx.providers["Thunderforest"]) # requires token
display(cx.providers["NASAGIBS"])
fig, axes = pyplot.subplots( 1, figsize=(16, 8))
dataset_gdf.plot( column = "wkd_day_value",
ax=axes,
legend = True,
scheme='quantiles',
cmap='PiYG_r',
k=8 # very useful
)
# scheme, methods for making the classes
# cmap: color scheme
cx.add_basemap( axes,
crs = dataset_gdf.crs.to_string(),
source=cx.providers.NASAGIBS.ViirsEarthAtNight2012
)
axes.set_axis_off()
pyplot.show()
That seems like an interesting correlation right there with "wkd_day_value", and funny enough I actually decided on the nightlight_450 and nightlight_900.
fig, axes = pyplot.subplots( 1, figsize=(18, 12))
dataset_gdf.plot( column = "nightlight_900",
ax = axes,
legend = True,
scheme = 'quantiles', # https://pysal.org/mapclassify/
cmap = 'magma',
edgecolors = 'green',
linewidth = 2,
k = 10, # very useful
# pct=[10,20,30,40,50,60,70,80,90,100],
legend_kwds={ 'title': 'Night Light',
'ncol': 4,
'facecolor': "#c0c0d0",
'edgecolor': "#000000",
'framealpha': 1,
# 'labelcolor': "markerfacecolor", # yeah looks silly ;)
'markerscale': 1.2,
'title_fontsize': 16,
'fontsize': 18,
'handletextpad': 0.1,
# 'frameon': False,
'shadow': False,
'mode': "expand",
'loc': "lower left",
# specifies the bbox (x, y, width, height):
'bbox_to_anchor': (0.0, -0.08, 1, -0.0),
'borderpad': 0.6,
'borderaxespad': 0
}
)
# scheme, methods for making the classes
# cmap: color scheme
cx.add_basemap( axes,
crs = dataset_gdf.crs.to_string(),
source = cx.providers.NASAGIBS.ViirsEarthAtNight2012
)
axes.set_axis_off()
pyplot.show()
Scheme seems to closely match the background. No idea how to get green circles around the spots in the legend, though.
And a look at the quantiles in use:
# Extract the quantiles.
nightlight_900_Series = dataset_gdf['nightlight_900']
type(nightlight_900_Series) # pandas.core.series.Series
mapclassify.Quantiles( nightlight_900_Series, k=10 )
Quantiles Interval Count ---------------------- [ 0.00, 0.16] | 49 ( 0.16, 2.32] | 48 ( 2.32, 5.94] | 48 ( 5.94, 9.46] | 48 ( 9.46, 13.26] | 48 (13.26, 16.19] | 48 (16.19, 19.83] | 48 (19.83, 23.79] | 48 (23.79, 30.88] | 48 (30.88, 72.91] | 49
# mapclassify.EqualInterval( quantiles, k=8 )
mapclassify.Percentiles( nightlight_900_Series, pct=[10,20,30,40,50,60,70,80,90,100] )
Percentiles Interval Count ---------------------- [ 0.00, 0.16] | 49 ( 0.16, 2.32] | 48 ( 2.32, 5.94] | 48 ( 5.94, 9.46] | 48 ( 9.46, 13.26] | 48 (13.26, 16.19] | 48 (16.19, 19.83] | 48 (19.83, 23.79] | 48 (23.79, 30.88] | 48 (30.88, 72.91] | 49
from pointpats import PointPattern, as_window
from pointpats import PoissonPointProcess as csr
from libpysal.weights import Queen, Rook, KNN, Kernel
import splot
import esda
import pysal
# use a continuous measure of distance to define neighbourhoods.
# warnings should be gone soon
# https://github.com/shapely/shapely/pull/1174
continuos_Dist = KNN.from_dataframe( dataset_gdf, k = 10 )
# type(continuos_Dist)
C:\_D\_Semester_15\Introduction_to_statistical_methods_for_spatial_data_analysis\Anaconda\envs\Course\lib\site-packages\libpysal\weights\util.py:1073: ShapelyDeprecationWarning: The array interface is deprecated and will no longer work in Shapely 2.0. Convert the '.coords' to a numpy array instead. data = np.vstack([np.array(shape.centroid) for shape in first_choice])
Try them all..
import warnings
# warnings should be gone soon
# https://github.com/shapely/shapely/pull/1174
with warnings.catch_warnings(record=True):
# Using the Rook neighbourhood
moran_I_Roo = esda.Moran( dataset_gdf['nightlight_900'],
Rook.from_dataframe(dataset_gdf)
)
moran_I_Roo.I
# Using the Queen neighbourhood
moran_I_Que = esda.Moran( dataset_gdf['nightlight_900'],
Queen.from_dataframe(dataset_gdf)
)
moran_I_Que.I
# Use the KNN weights
moran_I_KNN = esda.moran.Moran( dataset_gdf['nightlight_900'],
KNN.from_dataframe( dataset_gdf,
k = 10
)
)
moran_I_KNN.I
# Use the gaussian Kernel with fixed weight
moran_I_KFW = esda.moran.Moran( dataset_gdf['nightlight_900'],
Kernel.from_dataframe( dataset_gdf,
fixed=True,
function='gaussian'
)
)
moran_I_KFW.I
# Use the gaussian Kernel with adaptive weight
moran_I_KAW = esda.moran.Moran( dataset_gdf['nightlight_900'],
Kernel.from_dataframe( dataset_gdf,
fixed=False,
function='gaussian'
)
)
moran_I_KAW.I
print("Using rook and queen, Moran's I gives %.4f and %.4f, respectively." % ( moran_I_Roo.I, moran_I_Que.I), "Not what I expected." )
Using rook and queen, Moran's I gives 0.2383 and 0.2383, respectively. Not what I expected.
print("The 10 nearest neighbouts have:\t\t\t%.4f." % (moran_I_KNN.I) )
print("The gaussian Kernel with fixed weight:\t\t%.4f." % (moran_I_KFW.I) )
print("The gaussian Kernel with adaptive weight:\t%.4f." % (moran_I_KAW.I) )
The 10 nearest neighbouts have: 0.1977. The gaussian Kernel with fixed weight: 0.1172. The gaussian Kernel with adaptive weight: 0.6350.
with warnings.catch_warnings(record=True):
print("Results for nightlight_900 with k equal..")
for keigh in (4,5,8,10):
loop_moran_I_KNN = esda.moran.Moran( dataset_gdf['nightlight_900'],
KNN.from_dataframe( dataset_gdf,
k = keigh
)
)
print("%d:\t%.4f,\tp-value: %f" % (keigh, loop_moran_I_KNN.I,loop_moran_I_KNN.p_sim))
Results for nightlight_900 with k equal.. 4: 0.2843, p-value: 0.001000 5: 0.2645, p-value: 0.001000 8: 0.2272, p-value: 0.001000 10: 0.1977, p-value: 0.001000
with warnings.catch_warnings(record=True):
print("Results for nightlight_450 with k equal..")
for keigh in (4,5,8,10):
loop_moran_I_KNN = esda.moran.Moran( dataset_gdf['nightlight_450'],
KNN.from_dataframe( dataset_gdf,
k = keigh
)
)
print("%d:\t%.4f,\tp-value: %f" % (keigh, loop_moran_I_KNN.I,loop_moran_I_KNN.p_sim))
Results for nightlight_450 with k equal.. 4: 0.2391, p-value: 0.001000 5: 0.2208, p-value: 0.001000 8: 0.1899, p-value: 0.001000 10: 0.1629, p-value: 0.001000
Yes it differs, not very much but a bit more than with wkd_day_value.
with warnings.catch_warnings(record=True):
from splot.esda import plot_moran
plot_moran( esda.moran.Moran( dataset_gdf['nightlight_900'],
KNN.from_dataframe( dataset_gdf,
k = 10
)
),
zstandard=True,
figsize=(16,8)
)
pyplot.show()
with warnings.catch_warnings(record=True):
# Using the Rook neighbourhood
local_moran_I_Roo = esda.moran.Moran_Local( dataset_gdf['nightlight_900'],
Rook.from_dataframe(dataset_gdf)
)
# Using the Queen neighbourhood
local_moran_I_Que = esda.moran.Moran_Local( dataset_gdf['nightlight_900'],
Queen.from_dataframe(dataset_gdf)
)
# Use the KNN weights
local_moran_I_KNN = esda.moran.Moran_Local( dataset_gdf['nightlight_900'],
KNN.from_dataframe( dataset_gdf,
k = 10
)
)
# Use the gaussian Kernel with fixed weight
local_moran_I_KFW = esda.moran.Moran_Local( dataset_gdf['nightlight_900'],
Kernel.from_dataframe( dataset_gdf,
fixed=True,
function='gaussian'
)
)
# Use the gaussian Kernel with adaptive weight
local_moran_I_KAW = esda.moran.Moran_Local( dataset_gdf['nightlight_900'],
Kernel.from_dataframe( dataset_gdf,
fixed=False,
function='gaussian'
)
)
from splot.esda import moran_scatterplot
fig, axes = pyplot.subplots( 2, 2,
figsize=(14,10),
subplot_kw = {'aspect': 'equal'}
)
moran_scatterplot( local_moran_I_Que,
p=0.05,
aspect_equal=True,
ax=axes[0,0]
)
axes[0,0].set_xlabel('Night Light 900')
axes[0,0].set_ylabel('Spatial Lag of Night Light')
moran_scatterplot( local_moran_I_KNN,
p=0.05,
aspect_equal=True,
ax=axes[0,1]
)
axes[0,1].set_xlabel('Night Light 900')
axes[0,1].set_ylabel('Spatial Lag of Night Light')
moran_scatterplot( local_moran_I_KFW,
p=0.05,
aspect_equal=True,
ax=axes[1,0]
)
axes[1,0].set_xlabel('Night Light 900')
axes[1,0].set_ylabel('Spatial Lag of Night Light')
moran_scatterplot( local_moran_I_KAW,
p=0.05,
aspect_equal=True,
ax=axes[1,1]
)
axes[1,1].set_xlabel('Night Light 900')
axes[1,1].set_ylabel('Spatial Lag of Night Light')
pyplot.show()
from splot.esda import lisa_cluster
lisa_cluster( local_moran_I_KFW,
dataset_gdf,
p=0.05,
figsize = (9,9)
)
pyplot.show()
with warnings.catch_warnings(record=True):
print("Results for nightlight_900 with k equal..")
for keigh in (4,5,8,10):
loop_local_moran_I_KNN = esda.moran.Moran_Local( dataset_gdf['nightlight_900'],
KNN.from_dataframe( dataset_gdf,
k = keigh
)
)
print(loop_local_moran_I_KNN.Is)
Results for nightlight_900 with k equal.. [-1.69480216e-01 -9.93099411e-02 1.75892719e-01 1.85258560e+00 2.94998755e+00 5.04923795e+00 1.14559255e+00 1.58509605e+00 1.76515051e-02 2.74798811e+00 2.22043712e+00 2.04158530e+00 -1.86625163e+00 3.82303079e+00 5.56163011e+00 2.52383659e+00 2.63302965e+00 -4.70828897e-01 -1.06867898e+00 5.34721822e+00 1.22063050e-01 7.66412820e-02 5.71978265e-02 8.58361384e-02 -2.19957550e-01 1.44422473e-01 -5.15796644e-01 -1.09149433e-02 8.57832856e-04 3.32696341e-01 -6.92018894e-02 1.82942142e-01 -7.23183463e-02 1.19190675e+00 4.80632485e-02 2.90978390e+00 2.59332297e+00 3.02372932e+00 3.63545680e+00 2.72563559e+00 5.49220303e+00 7.65812983e+00 3.41505113e-01 8.90743582e-01 6.17172269e-02 3.32953553e-01 1.17723535e+00 -2.86308021e-02 -4.75203533e-03 -2.05961379e-02 -4.62134345e-01 -1.20708583e-02 -1.11123632e-01 -3.12927105e-03 -7.55679108e-02 -5.01751068e-01 2.49760913e-01 7.56250202e-01 -3.23855275e-01 -8.81328550e-01 1.95801005e-01 2.23624195e-01 -3.61061374e-01 -8.40261661e-02 -9.63048237e-02 1.25563786e+00 2.05765308e-01 -2.79391039e-02 -1.90488137e-01 3.33801704e-01 4.07071214e-01 -4.54579726e-01 3.10443518e-01 1.23399378e+00 1.42050619e-03 5.83478104e-01 7.57728828e-02 5.49197647e-01 -6.20510901e-01 -1.15763650e+00 5.00741032e-01 7.80231654e-01 1.32195377e-01 -7.45123829e-01 -6.89357748e-02 2.83141965e-01 -1.70950529e-01 6.13643588e-01 4.90434012e-01 1.13558611e-01 -4.80037973e-01 2.18305904e+00 -1.54905608e-01 -1.49028035e-02 1.42283251e+00 6.29406893e-01 -1.01353998e-01 2.30469564e-01 1.00334600e-01 1.84225512e-02 -7.66781132e-02 4.36030265e-01 -4.51672522e-01 4.33468182e-02 -2.21827435e-02 7.90697109e-01 -2.42178869e-01 4.91805630e-03 5.58278073e-02 -3.65642468e-01 -2.42576645e-01 -5.36649982e-02 8.51308642e-03 1.26483286e-01 8.09031950e-01 1.03162532e-02 5.14614883e-01 -8.50151624e-03 -1.62444010e-01 -2.27823100e-01 -2.43240002e-01 -2.26375618e-02 1.15356463e-01 2.15459276e-02 -4.93726569e-02 -8.89972844e-03 1.03030903e-01 8.55571084e-01 8.53479740e-03 1.49665609e-01 5.98643845e-02 5.07179727e-01 2.87351940e-01 -3.89346121e-01 5.42979171e-02 1.20602265e-02 2.12472802e-01 -4.66844822e-01 1.47198789e-02 8.06949960e-02 2.38398234e-01 -5.97625194e-01 -3.50248140e-01 -1.89828793e-01 -1.48355276e-01 2.17821636e-01 3.14721779e-01 -1.43346107e-01 4.34565850e-01 -1.45799094e-01 -1.33933034e-01 3.59404241e-01 -3.02012662e-01 -1.27835194e-01 5.48296715e-01 -5.58951868e-01 3.05608013e-02 1.75890676e-01 3.59247371e-01 4.38331172e-01 6.33812858e-01 -2.80882362e-03 -7.45298641e-02 1.00468890e-02 -9.36011593e-03 -2.07920616e-02 8.78124317e-01 5.53233335e-01 1.23848060e-01 -6.55013204e-02 1.35025738e-01 4.98111237e-01 5.29256921e-01 8.75944359e-02 1.48097702e-01 6.83426528e-01 4.27977040e-01 6.32256521e-01 4.07145221e-01 6.11048523e-01 -2.32785875e-02 8.75293208e-01 4.86152016e-01 -5.46228041e-01 4.96897298e-01 1.07820280e+00 1.39515473e-01 -9.83192370e-01 7.51269677e-01 2.30912758e+00 -2.32197288e-01 -3.91773654e-02 1.38242384e-01 7.21911785e-01 2.01888065e+00 -6.23080092e-02 -3.36095862e-01 3.17381290e-02 -1.60255971e-01 -2.61412997e-01 4.75355203e-02 -8.56770936e-01 -5.95285211e-01 2.57547662e-02 -2.66118120e-01 2.38456547e-01 -4.55779928e-01 -2.96082613e-01 3.17319977e-02 -3.10234017e-01 3.34149923e-02 1.01788463e-02 3.16570433e-01 -2.47207798e-01 -4.14163068e-01 1.14051297e-01 3.48205893e-01 7.60803125e-02 7.06098786e-02 1.62790702e-01 -1.46411745e-01 4.44342885e-01 -2.93294185e-01 4.12647953e-01 -5.75917341e-02 3.24006248e-01 2.87328383e-01 7.93707600e-01 3.55238603e-01 -9.14400018e-01 8.95240179e-01 -1.89991510e-02 8.02581557e-05 1.25023770e-01 3.89410684e-01 2.18413164e-01 -9.11688628e-02 4.34852310e-01 9.39426756e-01 5.46588237e+00 1.92839767e+00 2.34086603e+00 3.81872394e+00 -1.13223834e-01 -1.35862400e-01 -1.05399823e-01 -4.54669230e-02 1.02142717e-01 -1.00885474e+00 1.51098094e+00 2.36164792e-01 2.04533348e-01 3.76363420e-01 -6.44965178e-02 -2.00028644e-02 -2.94936304e-01 -5.56792635e-02 -7.17515417e-01 6.36133912e-02 -3.33968713e-01 2.98433738e-01 3.95787723e-01 9.71558095e-02 -6.62618794e-02 -3.22058943e-01 3.01161011e-04 -1.66273254e-01 -3.51475509e-01 1.27643874e-01 -3.33968713e-01 -1.84780113e-01 5.01617449e-01 -2.32153476e-02 1.36837697e-01 2.54829313e-01 -7.26923512e-01 -4.52326189e-02 4.92164792e-01 1.03255817e+00 8.61925747e-01 2.07151906e+00 3.91654062e-02 2.67237941e-01 1.09320862e-01 1.11783950e+00 1.38064688e+00 -8.08360704e-03 1.07642278e+00 4.10428022e-01 -9.41244930e-02 6.30489911e-01 6.34758539e-02 6.44573217e-01 1.26242012e-01 4.75195286e-01 -1.42107122e-02 -4.89121585e-02 -3.45854331e-01 -4.90205079e-02 -2.42527959e-03 -1.43401407e-01 -4.76363807e-01 4.13638033e-01 -3.91461475e-01 7.94863213e-02 5.17837743e-02 3.36118234e-01 7.10351769e-01 4.35769608e-01 1.06870907e+00 3.57341634e-01 3.13850627e-01 6.50733655e-01 -1.06353452e-01 -7.45197720e-01 8.62796709e-01 1.46706179e-01 3.74015661e-02 2.48590542e-01 7.91011245e-01 7.87136336e-01 1.17560878e-02 4.93507398e-01 -1.79058731e-01 5.36355415e-01 1.68853978e-01 -7.39193616e-01 8.92389006e-01 1.31589132e-01 8.90901221e-01 -2.21183953e-01 -4.98627312e-01 -1.91859626e+00 1.43977757e-01 2.27947965e-01 7.74321041e-02 2.39756039e-01 2.83305390e-01 2.82684752e-01 1.89873156e-01 -3.56879380e-01 -1.79911313e-02 7.69060374e-02 -2.66082538e-02 1.08314552e-01 -1.01512427e-01 1.25224923e-01 -7.58395663e-02 4.41174614e-01 9.64338875e-02 -1.24118330e-02 6.64067975e-01 1.02839901e+00 -7.39193616e-01 -1.26158791e+00 9.89916534e-03 1.54511421e-02 7.85624659e-01 1.32701349e-01 1.24069237e-01 -6.16681082e-01 1.25598529e-01 -1.90547231e-01 -4.91831835e-01 8.15194667e-01 5.30416392e-01 4.56466542e-01 -3.58369603e-03 9.99911654e-02 1.82747656e-01 2.04142329e-01 2.23658775e-01 2.32853632e-01 5.36660757e-01 -9.22992278e-03 3.21791287e-02 -4.47753625e-02 -3.49476307e-01 1.87144380e-01 -3.16061284e-02 1.78961334e-01 1.93095826e-01 -7.97819498e-03 -8.71522070e-03 -8.71522070e-03 -1.51917587e-01 -7.43414182e-02 -3.36099193e-01 -1.23541602e-01 9.41531902e-03 -1.05059411e-02 3.25436437e-03 -7.52213065e-01 2.79031687e-01 8.13701372e-02 -9.55322946e-02 -1.02637213e-01 2.96417338e-02 -5.16690912e-01 6.55218667e-02 -5.33115130e-01 4.01837617e-02 -1.27011685e-02 1.92681115e-03 6.94113353e-02 -5.42171060e-01 2.52927987e-01 -3.51205526e-01 -4.41573602e-03 1.02350831e+00 2.87076458e-01 -2.08738924e-02 -4.53944203e-01 2.99794984e-01 6.45850551e-02 -1.22708252e-01 3.03908749e-01 3.11932463e-02 2.35047864e-01 2.84012542e-01 2.84314689e-01 2.84346470e-01 1.47515173e-01 5.46757396e-01 -2.32742259e-01 -4.61200347e-02 1.58651579e-01 2.89611304e-01 4.44702619e-01 5.16680730e-01 5.00901410e-01 -1.74696481e-02 -4.85783260e-01 -2.71462638e-02 -4.53997825e-02 -4.97122438e-02 -9.83675644e-01 -2.80811212e-01 -1.86265384e+00 4.03909732e-01 3.54242050e+00 4.77923294e-01 -1.16335906e-01 8.71559571e-01 9.50262496e-01 -4.27176604e-02 8.51900517e-02 1.76522465e+00 6.06999932e-01 2.57254870e-01 -2.03362026e-01 4.37367929e-01 4.60083800e-01 8.58231163e-01 9.96849214e-02 1.27091289e+00 -9.89107943e-01 3.26845303e-03 1.21438713e-01 -2.24437551e-01 -2.64778179e-01 -6.41743760e-02 -2.45117327e-01 1.78013104e-02 -1.99021614e-01 2.66054505e-02 4.20145071e-01 5.08165369e-01 7.43603484e-01 3.25394097e-01 4.50579337e-01 3.24284204e-01 -2.53571199e-01 1.82093546e-02 1.60976944e-01 2.00844793e-01 4.70154979e-02 -7.11675795e-02 -3.29133328e-02 4.47922495e-01 3.55284165e-01 -6.80965714e-02] [-3.81662381e-01 -2.15891630e-01 1.66217163e-01 2.94368065e+00 2.91672343e+00 5.31252039e+00 1.13519730e+00 1.04699529e+00 -1.49454523e-01 2.41711375e+00 3.27993142e+00 1.86010939e+00 -1.88731961e+00 3.80772378e+00 5.95288581e+00 2.46437281e+00 2.57449044e+00 -2.06005921e-01 -8.70357542e-01 3.80004491e+00 -2.94944399e-03 -8.32647613e-02 6.25804717e-02 5.32545498e-02 -1.63832546e-01 4.36069262e-02 2.18027058e-01 -8.38150737e-02 7.65956301e-02 9.60775484e-02 -4.01789259e-02 2.38638335e-01 5.21579526e-02 9.37321588e-01 -3.13951145e-01 2.75903321e+00 2.89824883e+00 2.74395900e+00 3.58571658e+00 2.50548401e+00 5.21735288e+00 6.45820734e+00 1.90023894e-01 7.27404444e-01 -3.64593071e-01 3.09080257e-01 1.55419358e+00 -1.16636461e-01 -2.61668328e-02 -5.08951699e-02 -5.39787001e-01 2.84263289e-03 -1.57294209e-02 -1.64236710e-03 3.61957883e-02 -5.72877882e-02 2.17045729e-01 8.66325871e-01 -2.44159084e-01 -7.69919335e-01 2.53290921e-01 2.67335844e-01 -1.07289210e-01 -2.69502175e-01 -3.61012529e-03 1.26467349e+00 -5.98297900e-02 1.01905723e-02 -3.56567626e-01 3.85626665e-01 5.86797551e-01 -1.01748106e-01 -8.81308035e-03 1.21260810e+00 1.96110409e-03 1.89612952e-01 1.31200701e-01 1.90789153e-01 -3.63308658e-01 -1.27746062e+00 4.61993991e-01 -2.42853465e-01 2.68599868e-01 -6.74731494e-01 -4.80891633e-02 2.19664317e-01 2.21937642e-03 8.39258820e-01 4.44157585e-01 1.30679823e-01 3.28046238e-02 1.91694169e+00 -1.28427771e-01 -5.18718054e-02 1.32721816e+00 3.73616564e-01 -8.79324541e-02 1.87399450e-01 8.12260379e-02 1.02184207e-02 -1.81641150e-01 3.67499255e-01 -3.28048275e-01 2.88838669e-01 -9.18043011e-03 4.89840704e-01 -1.96819522e-01 5.92062854e-03 -2.25501883e-02 -3.61724687e-01 -1.82634602e-01 -3.24172091e-02 1.18442113e-02 8.80682490e-02 4.89837357e-01 1.88861057e-03 3.42481194e-01 3.84237616e-02 -1.34474828e-01 -1.58072923e-01 -2.00523915e-01 -5.08340939e-02 7.64398963e-02 -1.97315900e-02 -2.89833360e-02 -3.90984606e-03 4.39994515e-02 5.46461666e-01 1.15715055e-02 6.26967442e-02 2.14682013e-02 9.61572110e-02 3.32447365e-01 -1.79794308e-01 1.33817511e-02 1.13549815e-02 1.43554935e-01 -2.15051136e-01 2.30500359e-02 1.11853320e-01 3.68858775e-01 -3.28679523e-01 -1.88620024e-01 -1.47749076e-01 -1.15210998e-01 1.54382889e-01 3.06133204e-01 -1.04554069e-01 3.55357654e-01 -1.48095392e-01 -1.14888485e-01 4.56957374e-01 -1.88430570e-01 -2.44998034e-01 3.79867321e-01 -5.53316962e-01 3.21536148e-02 1.96495769e-01 4.56036415e-01 4.67672538e-01 3.72803285e-01 -8.40276356e-03 -3.17709233e-02 8.88943534e-03 -8.24059359e-03 9.16479452e-02 7.56459442e-01 4.49497225e-01 8.63887363e-02 -7.06902122e-02 2.18243171e-01 6.71605883e-01 7.50032284e-01 1.02037207e-01 2.26493092e-01 5.78702880e-01 3.32795067e-01 5.32887401e-01 3.40005625e-01 5.44302452e-01 -2.68852675e-02 5.75029617e-01 5.44782414e-01 -5.64126489e-01 2.74379813e-01 1.25883457e+00 2.41627330e-01 -8.62091411e-01 5.29951745e-01 2.10850074e+00 -4.29403022e-01 -4.46278394e-02 2.05578400e-01 6.32993062e-01 1.81549876e+00 -5.94005402e-02 -3.57518515e-01 1.43862581e-01 2.05967252e-02 -3.41897819e-01 9.19884046e-02 -5.65573448e-01 -2.77177779e-01 8.05045800e-03 -2.78322816e-01 5.74700672e-02 -3.91660129e-01 -7.56048808e-02 4.45217041e-02 -4.05337735e-01 3.10386899e-02 2.55630906e-01 3.68448455e-01 -2.59438830e-01 -3.80451448e-01 1.42096612e-01 4.27366216e-01 1.67297770e-01 1.44403366e-01 1.63160923e-01 -2.09118162e-01 2.32535861e-01 -2.44475324e-01 2.31277904e-01 -5.35561132e-01 1.93776678e-01 1.20616758e-01 4.11868362e-01 2.13758941e-01 -6.77331883e-01 6.05947365e-01 6.14730775e-02 7.50149261e-04 1.05070302e-02 2.60980979e-01 8.54705286e-02 -8.97603460e-02 5.78074038e-01 8.60772546e-01 3.95909021e+00 1.84450708e+00 2.17448177e+00 3.24565322e+00 -1.32004398e-01 4.32618501e-03 -1.23650631e-01 -6.56714535e-02 1.54401668e-01 -8.46414566e-01 1.27218800e+00 4.48902922e-01 3.98236445e-02 2.82520680e-01 2.47023900e-02 -1.26247070e-01 -3.18706587e-01 -5.07393482e-02 -7.41582866e-01 -5.68939734e-02 -7.20388185e-03 -1.47926720e-01 4.89318848e-01 1.06811210e-01 -7.15795594e-02 -4.31991759e-01 1.46435162e-01 -1.78792199e-01 -3.70555433e-01 -4.70053513e-02 -7.04807004e-02 -2.77397204e-01 2.33723426e-01 -1.40778206e-02 9.02881755e-01 6.66580075e-01 -6.93608324e-01 -2.61841135e-02 2.18661670e-01 1.05370892e+00 8.73945212e-01 2.31011755e+00 5.67851118e-02 2.87042042e-01 1.75752887e-01 1.14478098e+00 1.43203492e+00 -1.29120299e-01 1.51404052e+00 3.80661565e-01 -1.10638946e-01 6.60191541e-01 -1.01591486e-02 6.45156963e-01 1.63126066e-01 2.79769495e-01 3.30590933e-02 -2.56040512e-02 -3.78679209e-01 -6.16926593e-02 -1.23227625e-02 -1.49361469e-01 -5.41789670e-01 4.32073863e-01 -3.08325711e-01 1.37193503e-02 5.62033758e-02 1.08195963e-01 5.82628357e-01 3.21382600e-01 7.20503343e-01 4.14845900e-01 3.60704105e-01 7.38739208e-01 -1.10124053e-01 -6.43847374e-01 6.50737943e-01 8.36097996e-02 2.11836240e-02 1.08332271e-01 4.89559431e-01 4.87650143e-01 1.23979567e-02 4.03961822e-01 -1.83329421e-01 5.29783219e-01 1.85787459e-01 -4.93085489e-01 9.04889357e-01 1.28426589e-01 9.03196876e-01 -2.16446586e-01 -5.40960776e-01 -2.56675500e+00 6.74930084e-02 3.59392227e-02 4.85973257e-02 1.31120283e-01 1.26353426e-01 1.31017771e-01 1.09401747e-01 -3.13946736e-01 -7.63510773e-02 7.27480778e-02 -1.98945645e-02 1.05431890e-01 -2.27629091e-01 1.69105546e-01 6.48698099e-02 1.77245510e-01 1.14975409e-01 5.04559528e-02 4.21592310e-01 7.74500961e-01 -7.07885532e-01 -1.10491257e+00 2.53459093e-03 -1.58397377e-03 8.90524373e-01 1.16585336e-01 1.13399368e-01 -3.88075736e-01 8.71304655e-02 -1.42487047e-01 -4.35962246e-01 8.62813140e-01 5.29602243e-01 8.37617313e-01 2.81111407e-03 9.84974893e-02 1.15544729e-01 -1.34319351e-01 1.21679554e-02 1.18913728e-01 4.43472584e-01 -1.30787626e-02 -2.04936778e-02 -5.65341498e-02 -1.48555776e-01 4.61625492e-02 -1.67387768e-01 1.75664037e-01 3.13478630e-01 -2.98925749e-02 -2.61812236e-02 -2.61812236e-02 -1.06903850e-01 -7.62207432e-02 -2.00774372e-02 -1.06069766e-01 -4.23218961e-03 3.08669580e-03 -1.68660942e-01 -5.67180436e-01 3.31674209e-01 5.78596252e-02 -3.28833865e-01 -1.16272011e-01 3.50388210e-02 -1.64550812e-01 4.47387019e-02 -7.28042168e-01 4.47912822e-02 1.77952927e-01 1.49262715e-03 4.21760668e-02 -4.43716803e-01 1.44502991e-01 -7.36088551e-01 1.28835837e-02 5.65039132e-01 2.89073461e-01 -2.52043617e-02 -3.28775615e-01 -2.79197182e-01 6.43123169e-02 -3.64233436e-02 3.99283792e-01 4.56693334e-03 1.88688320e-01 1.97605390e-01 1.97806341e-01 2.38716005e-01 3.41264566e-01 4.48833894e-01 -2.83366182e-01 2.54643467e-02 1.17414251e-01 4.26506215e-01 4.14103566e-01 5.22497923e-01 6.60648975e-01 -2.25442099e-02 -3.03171387e-01 -1.33086006e-02 -2.11137824e-02 -1.18671975e-01 -9.08187069e-01 -3.16294565e-01 -1.27966094e+00 3.66550673e-01 2.97027558e+00 6.30296791e-01 -7.52716874e-02 1.10464092e+00 7.98154745e-01 -7.48799212e-02 8.27935091e-02 1.81957298e+00 6.74389236e-01 2.96951412e-01 -2.16706150e-01 3.64535811e-01 3.83530600e-01 7.17831486e-01 2.66631788e-01 1.06127062e+00 -8.27493138e-01 1.82404638e-01 1.89385967e-01 -1.27769610e-01 -2.76257068e-01 -8.26815687e-02 -1.78296824e-01 1.20483966e-02 -1.43968936e-01 2.36928485e-01 4.21424923e-01 5.00847397e-01 5.54352576e-01 3.33425857e-01 4.28941167e-01 2.76908457e-01 -2.35244303e-01 1.76548828e-02 2.69027547e-01 1.63763233e-01 3.99039257e-02 -5.90419229e-02 4.67799133e-02 3.68767941e-01 2.90705374e-01 -5.53615011e-02] [-6.87731641e-02 -3.58785150e-01 1.47138299e-01 2.93043840e+00 2.22612599e+00 5.09079457e+00 1.41551359e+00 1.59884793e+00 -4.73870776e-01 2.98035349e+00 2.94733563e+00 1.53326815e+00 -1.57041042e+00 3.50141054e+00 5.08321058e+00 1.94380000e+00 2.03325321e+00 -3.36265514e-01 -1.15451719e+00 3.23971603e+00 -9.95059570e-02 -1.78937235e-01 5.51615089e-02 7.25475892e-02 -3.17119560e-01 -2.87427939e-01 7.15495671e-01 -1.32457261e-01 1.17590630e-01 -1.37505586e-02 -6.65841999e-02 2.16260356e-01 1.16224719e-02 8.41193440e-01 -4.91756456e-01 3.49865822e+00 2.90051328e+00 2.73378690e+00 3.00958104e+00 1.99523901e+00 4.27863179e+00 6.61094758e+00 -1.23718371e-01 6.93750806e-01 -7.80790151e-01 3.15855311e-01 2.35826025e+00 -1.48753321e-01 -7.99004597e-02 -1.29601980e-01 -2.61652491e-01 -2.71641918e-02 -2.91781826e-01 7.88357587e-03 1.17981597e-01 5.05154230e-02 3.87830532e-01 3.86761501e-01 -2.86276815e-01 -2.31503951e-01 -1.60214935e-01 -1.24367886e-01 2.46788084e-01 -5.18101563e-01 1.24680987e-01 5.36794568e-01 1.17781783e-01 7.36676537e-02 -6.45105521e-01 3.12660208e-01 6.96736608e-01 3.35002494e-01 1.94957953e-02 4.24120171e-01 1.25795748e-03 -1.42231602e-01 8.47620656e-02 -1.14591272e-01 -4.88904710e-01 -1.42401304e+00 5.03940666e-02 -2.78112003e-01 4.57826675e-01 -3.97541600e-01 -2.78337214e-01 3.68421407e-01 8.96563587e-02 3.58424330e-01 2.90338601e-01 1.63589515e-01 -1.03019338e-01 1.06079353e+00 -7.80999766e-02 -2.05814796e-02 8.98264139e-01 5.84361774e-01 -5.74934509e-02 4.76839534e-01 1.64773688e-01 4.90713530e-03 -1.03442887e-01 3.81640041e-02 -2.39357827e-01 6.57914007e-01 -7.59101819e-03 1.39543457e-01 -2.11931056e-01 2.93827262e-03 6.74022113e-02 -1.70955086e-01 -7.20848333e-02 -3.15922970e-02 2.59318625e-02 3.97283345e-02 2.06481329e-01 1.98901039e-02 1.70222649e-01 9.42101862e-03 -1.00683513e-01 -5.37398343e-02 -1.47162850e-01 -3.80561445e-02 2.14721136e-02 -2.60910562e-02 -1.38349753e-02 -1.82460895e-03 2.77345689e-02 3.34268884e-02 1.44808428e-02 4.46729035e-02 2.13461221e-02 1.33723306e-01 5.88153689e-01 -7.98500112e-02 -1.15971658e-02 1.87317307e-02 -2.23992345e-02 -5.61654817e-01 9.12594541e-02 -5.76455055e-02 2.63453128e-01 -1.19910582e-01 -3.06632084e-02 -1.59203952e-01 -1.28454304e-01 -3.99024689e-03 8.81338180e-03 -1.41681400e-02 2.53259227e-01 -4.01488268e-02 5.40199884e-02 3.33787103e-01 -7.18260300e-02 -5.21044864e-01 2.47057632e-01 -3.76014794e-01 2.22873820e-02 1.85599158e-01 3.32985267e-01 4.35242514e-01 2.21954192e-01 -5.08769877e-02 1.86585650e-01 -4.46157568e-03 3.69801890e-03 2.17510978e-01 5.91144281e-01 3.04117495e-01 4.44030903e-03 -6.27268679e-02 1.43945174e-01 6.24865953e-01 7.14068646e-01 8.77766336e-02 1.72203257e-01 7.17457648e-01 3.62898786e-01 6.34509065e-01 3.71560756e-01 3.77529058e-01 -1.91474291e-02 6.25360102e-01 2.81602728e-01 -4.99916343e-01 1.51385004e-01 6.72144573e-01 3.11308801e-01 -5.03728022e-01 3.98412933e-01 1.25724381e+00 -4.97194331e-01 -3.35438777e-02 1.76467340e-01 3.43420557e-01 1.08821747e+00 -2.88630768e-02 -2.43603012e-01 2.70666356e-01 1.66281904e-01 -3.66836715e-01 1.19736964e-01 -1.49957488e-01 -4.26335115e-01 -1.62874116e-02 -2.50019311e-01 -3.33522020e-01 4.72021282e-03 3.19059437e-02 6.24065515e-02 -2.66091864e-02 1.23953326e-02 -1.97290574e-01 3.30175415e-01 -2.33850376e-01 -1.86949948e-01 1.47935529e-01 4.20705231e-01 3.04039666e-01 2.55023971e-01 1.75957500e-01 1.65764413e-01 3.19355377e-01 -1.04189180e-02 2.84458236e-01 -4.81821076e-01 2.13724792e-01 1.54393286e-01 5.42485156e-01 4.30939174e-02 -5.07779544e-01 3.04678809e-01 2.84757696e-02 3.79872098e-04 4.14436586e-01 4.30501850e-02 6.02803476e-02 -4.39527785e-02 3.34656827e-02 4.93213511e-01 2.47026332e+00 1.15162481e+00 1.23536029e+00 1.77821684e+00 3.07221771e-01 -6.79604148e-01 2.92737522e-01 -8.41508501e-02 2.03446573e-01 -6.61425205e-01 7.46551041e-01 7.27498639e-01 2.47444762e-02 4.03440337e-01 -9.23800011e-02 4.10325200e-01 -2.85528446e-01 -1.78260590e-03 -6.38307292e-01 -2.02942377e-02 5.78078455e-02 -2.10080984e-01 3.72444487e-01 8.59284836e-02 -5.69770829e-02 -7.90653167e-01 5.56085437e-02 -1.45846958e-01 -2.98182525e-01 -2.68041156e-01 4.10651095e-01 -5.60327123e-01 2.25142300e-01 -4.98578443e-03 1.14337121e+00 7.54325491e-01 -6.87323660e-01 -2.56736646e-02 4.72455739e-01 8.82057185e-01 7.27240058e-01 2.02919062e+00 7.34846011e-02 1.53941183e-01 2.41647131e-01 9.61405420e-01 1.21653554e+00 -1.23006936e-01 1.25006699e+00 3.17607165e-01 -1.63046335e-01 1.08357913e+00 -2.73693981e-02 7.11631072e-01 1.87565063e-01 4.63461636e-01 7.23032371e-03 -1.29563823e-02 -5.42727127e-01 -6.30521736e-03 7.19688020e-03 -4.36431477e-02 -4.48262995e-01 6.15811700e-01 -1.04153355e-01 9.88763523e-03 6.33924570e-02 2.60533025e-01 4.60258872e-01 2.12163917e-01 5.57189529e-01 3.33311943e-01 2.88366553e-01 -1.32831560e-01 -2.86146360e-02 -1.46808114e-01 5.76268642e-01 -1.27640992e-03 6.54617370e-03 -1.53872846e-01 7.34539424e-01 6.25843687e-01 6.30226406e-03 2.48949400e-01 -9.52103834e-02 2.70599928e-01 9.16134762e-02 -5.80810448e-02 5.13783437e-01 4.55043440e-01 5.12861792e-01 -1.78461749e-01 -5.03666162e-01 -2.09539376e+00 1.63473579e-02 3.35350041e-01 3.61306147e-03 1.99589413e-01 2.73388474e-01 2.66299180e-01 2.30105591e-01 -7.21820321e-02 -1.43077302e-01 -1.62383982e-02 -1.47623036e-02 -3.73597595e-02 -3.43041653e-01 5.46505149e-01 2.12689115e-01 -2.25830849e-01 -1.76218945e-02 -1.09009484e-01 3.50309641e-01 -1.96114081e-02 -7.10678035e-01 -8.82870429e-01 2.92745971e-02 7.07201640e-02 8.00801582e-01 6.26879735e-02 7.22673427e-02 2.79581937e-01 6.96168176e-02 -7.16356693e-03 -4.38609713e-01 9.84256001e-01 5.53374452e-01 1.52151309e+00 -1.35743115e-03 5.03993910e-02 -2.23344768e-02 -1.95472328e-01 -5.48794074e-02 2.29519042e-01 3.06989092e-01 -1.38231394e-02 6.44661782e-02 -1.11878902e-02 -6.64697458e-02 4.57908200e-02 -4.65951650e-01 2.16689022e-01 2.58219910e-01 -2.05373375e-01 -2.19657877e-02 -1.60106885e-02 -1.62164829e-01 -3.24609032e-01 1.71303560e-01 -1.33302781e-01 -2.20278832e-02 2.08621689e-02 -3.87583498e-01 -4.05926569e-01 2.94701235e-01 5.84472395e-02 -6.21381456e-01 6.05298723e-05 4.93187743e-02 3.07074705e-01 1.47964022e-01 -4.80601627e-01 5.71484203e-02 2.29465508e-01 1.08291593e-03 3.01383989e-02 -2.92848781e-01 1.36911103e-01 -1.67715738e-01 1.00714386e-02 3.44592901e-01 3.16093049e-01 -2.16528666e-02 -2.07023859e-01 -3.49921643e-01 1.15723046e-01 -5.29291870e-02 4.96103748e-01 1.28147028e-02 2.98116086e-02 -1.00491564e-01 -1.00674415e-01 1.39129234e-01 3.84804667e-01 3.37129065e-01 -2.51756818e-01 7.70211718e-02 1.36850426e-01 3.10133235e-01 3.36155008e-01 -4.73998072e-02 6.21216885e-01 3.15196272e-02 2.79764836e-01 -4.74638362e-03 7.62990581e-02 -6.37451048e-01 -5.85301723e-01 -2.89849573e-01 -7.51849157e-01 3.20619069e-01 1.69170951e+00 4.04494954e-01 -6.24596643e-02 7.35056284e-01 5.88481942e-01 -1.82319761e-01 2.14654505e-01 2.44084029e+00 3.84868369e-01 1.72712425e-01 -4.97446765e-01 2.94057688e-01 4.37305695e-01 5.13919047e-01 3.66759151e-01 9.02843586e-01 -7.28421253e-01 3.14435228e-01 8.10911562e-02 -1.35077155e-01 -4.58543843e-01 3.82718930e-01 -2.81671042e-01 2.85038065e-02 -2.35836983e-01 3.35240592e-01 1.58979091e-02 1.95083046e-01 3.48965798e-01 3.74055936e-01 5.86392391e-01 2.13616858e-01 -2.16614321e-01 1.76678097e-02 2.04426395e-01 3.50334036e-02 1.01925344e-01 -1.07716143e-01 1.37314208e-01 3.71557040e-01 1.84524008e-01 -4.65613618e-02] [-3.47177888e-01 -7.30801916e-01 1.72698493e-01 3.63755646e+00 2.71423570e+00 5.52817507e+00 1.49689642e+00 1.68355223e+00 -4.42648518e-01 2.72072243e+00 2.56676755e+00 1.36090734e+00 -1.41602998e+00 2.89526882e+00 4.96585037e+00 1.82137299e+00 1.90655006e+00 -6.32120862e-01 -1.22531303e+00 2.61114464e+00 9.78076080e-03 -2.54564893e-02 5.24870644e-02 6.50847129e-02 -4.55934470e-01 -4.83076468e-01 9.58406893e-01 -1.22614545e-01 1.40534302e-01 4.04461365e-01 -6.30422811e-02 3.43254491e-01 1.27386665e-01 1.26900170e+00 -8.15562199e-01 2.89415518e+00 2.42677213e+00 2.27196623e+00 2.43821051e+00 1.61563678e+00 3.44963268e+00 5.33727397e+00 -3.55327693e-01 5.96199949e-01 -7.45998044e-01 3.11268069e-01 2.72680295e+00 6.75532266e-03 8.59873394e-03 7.91950891e-03 -2.79251806e-01 -6.39330022e-02 -3.90440883e-01 2.60931861e-03 7.64903998e-02 -2.21434925e-02 -2.31000863e-01 1.27891215e-01 -1.61859491e-02 -5.56776739e-02 -3.46062784e-01 -2.98868102e-01 2.84164151e-01 -5.11113813e-01 1.34825105e-01 3.38804378e-01 2.32074898e-01 7.37001989e-02 -6.08731094e-01 1.20100256e-01 7.97938134e-01 4.90917781e-01 1.79638974e-01 2.93706589e-01 7.73614772e-04 6.66285912e-02 8.98589323e-03 -2.94440802e-02 -2.53925186e-01 -1.49263037e+00 -1.03571757e-01 -3.77200099e-01 5.30063619e-01 -3.08588267e-01 -1.67041301e-01 3.28316388e-01 3.17762156e-02 7.81944258e-01 2.59829551e-01 1.40003594e-01 -4.61225492e-02 6.31684202e-01 -6.61797536e-02 -1.99435056e-02 6.84380802e-01 3.10206885e-01 -8.55995267e-02 3.79622991e-01 1.33404966e-01 2.73233956e-03 -1.24253209e-01 -2.97415470e-01 -2.59958787e-01 7.52390870e-01 7.43718042e-03 3.83531841e-01 -1.42859814e-01 1.98601941e-03 2.27417893e-02 -2.19739728e-01 -3.64293957e-01 -2.19881053e-02 -1.14330670e-01 3.56908885e-02 1.54139529e-01 1.30721542e-02 1.31320898e-01 1.23206742e-02 4.07333289e-02 -9.64032809e-02 4.14475356e-02 -2.59884853e-02 3.76418712e-02 -1.62703712e-02 -1.07293584e-02 5.40091490e-03 3.23835412e-02 -1.52371452e-01 1.41108524e-02 -1.63253311e-02 2.58318471e-02 6.92892605e-02 5.32461564e-01 -4.41188688e-02 -3.23512348e-02 1.78535841e-02 -4.06312053e-02 -6.44787819e-01 8.59153119e-02 -1.04471706e-01 3.05443417e-01 -7.60829322e-02 2.74862732e-02 -5.68331747e-02 -4.32182725e-02 1.39068768e-02 4.83365548e-02 -2.00437371e-02 2.40065941e-01 2.15956367e-02 -2.21690079e-01 4.35372323e-01 -8.72896247e-02 -3.27373505e-01 2.04321477e-01 -4.06283545e-01 2.54852509e-02 1.74276485e-01 4.33940515e-01 1.88142600e-01 1.10293351e-01 -6.09074835e-02 2.40694950e-01 2.72063426e-03 -2.59742146e-03 -4.94297380e-02 3.87862445e-01 4.85667600e-01 -2.14004312e-02 -4.48887940e-02 2.44535608e-01 4.34240117e-01 4.92739415e-01 6.25382692e-02 4.56632279e-02 4.94928799e-01 2.55906106e-01 4.40636283e-01 2.61912527e-01 2.47429940e-01 -4.34393448e-03 6.14515002e-01 1.97766573e-01 -1.42049946e-01 1.50212674e-01 4.29759376e-01 -2.56059853e-02 -4.00339619e-01 2.63541574e-01 7.57012856e-01 -5.87592599e-01 -2.58977413e-02 2.17927933e-01 2.25574139e-01 6.79705781e-01 -2.59157861e-02 -3.65308822e-01 1.72593207e-01 1.09101446e-01 -3.61441184e-01 1.36069537e-01 -4.95248416e-02 -3.01597382e-01 -2.04085039e-02 -8.67005050e-02 -3.56517976e-01 3.43284404e-02 4.91599934e-02 5.40318374e-02 5.80670279e-02 1.70360670e-02 -2.82803362e-01 1.59011034e-01 -7.78325903e-02 -1.56250206e-01 3.02719365e-02 1.74914647e-01 1.34985739e-01 1.14606587e-01 7.97843468e-02 -1.11599571e-01 -1.49828786e-02 -4.83201935e-01 1.01154937e-02 -3.99161536e-01 2.70361467e-02 8.87077609e-02 3.90465654e-01 4.08169227e-02 -3.90552655e-01 4.79364299e-01 -1.87569765e-01 -1.57798314e-03 1.80320186e-01 -1.28681704e-01 3.91533745e-02 -5.26303837e-02 -1.15958963e-02 3.64555387e-01 2.31665983e+00 1.01867223e+00 9.05360210e-01 1.59254687e+00 2.50258185e-01 -8.60654801e-01 2.38444228e-01 -5.96941138e-02 1.43835912e-01 -5.06096889e-01 6.26025334e-01 6.14887870e-01 1.65223145e-01 4.97915298e-01 -1.31990916e-01 5.89258027e-01 -3.38635438e-01 -8.37636575e-03 -7.33808543e-01 -1.24864564e-01 2.86425604e-01 -4.67589913e-01 4.06700972e-01 5.74296939e-02 -3.83589232e-02 -9.07288996e-01 -1.20217183e-02 -1.34690010e-01 -2.73716134e-01 -5.31343083e-01 4.69375299e-01 -6.52468454e-01 2.04997644e-01 -3.88485261e-03 9.70203836e-01 7.70552263e-01 -6.50522675e-01 -2.58842243e-02 4.34278644e-01 9.24647232e-01 6.64627949e-01 1.73846481e+00 6.12851754e-02 1.58683059e-01 2.01981561e-01 8.81654983e-01 1.08761270e+00 -2.22567627e-01 1.26406742e+00 2.96228114e-01 -1.72173823e-01 8.68695713e-01 -8.35849241e-02 7.02150482e-01 1.62323939e-01 5.94778536e-01 3.25274230e-02 -1.93767064e-02 -5.01423328e-01 -1.99208725e-02 2.02142844e-02 1.33191403e-02 -3.62168511e-01 6.03132659e-01 -1.77176130e-01 -3.32799183e-02 7.02617585e-02 2.58961950e-01 4.01380129e-01 -5.26587893e-02 4.76867328e-01 2.70606884e-01 2.34056877e-01 1.18683756e-02 -1.11728410e-01 1.05715129e-01 4.24114654e-01 -2.86106989e-02 4.29231035e-03 -2.43139648e-01 7.21656432e-01 5.90920343e-01 2.62108155e-03 2.58351815e-01 -5.68157445e-02 2.81778824e-01 3.80152588e-02 1.99164265e-01 4.46624367e-01 2.66353363e-01 4.45793433e-01 -1.62365391e-01 -4.63414520e-01 -2.49584594e+00 -3.00296598e-02 3.63045507e-01 1.94377252e-02 4.08691853e-01 6.30256537e-01 6.03407422e-01 2.94992554e-01 -1.14020072e-02 -1.36448147e-01 -2.10661098e-02 -4.50210044e-03 -4.34006385e-02 -3.63317037e-01 6.22952046e-01 2.46361211e-01 -3.11137250e-01 8.98664878e-04 -2.48698456e-02 3.29753969e-01 1.06821739e-01 -4.79616734e-01 -8.53795658e-01 4.61920561e-02 1.15549856e-01 7.37457256e-01 8.30358861e-02 5.75729809e-02 3.52528221e-01 3.26946101e-02 -2.74674683e-02 -3.28896100e-01 9.07269579e-01 5.02598053e-01 1.48603276e+00 -6.44455465e-04 5.09133634e-02 -7.62774455e-02 -3.09220480e-01 -1.29538767e-01 3.26873696e-01 2.83545698e-01 -7.76256440e-03 -4.56285949e-01 3.44690187e-02 -3.14547715e-03 -2.77197424e-01 -2.73610419e-01 1.96545893e-01 -1.82558049e-01 -1.09326668e-01 1.35826290e-02 1.35826290e-02 6.55023019e-02 -2.46004678e-01 3.35422902e-01 -1.23949285e-01 -1.80284456e-02 1.70864496e-02 -3.15979289e-01 -3.42593878e-03 2.16678277e-01 4.92828330e-02 -5.05818942e-01 4.46583018e-02 5.07108114e-02 2.54249049e-01 2.44915608e-01 -2.03816566e-01 7.45720050e-02 3.67185480e-01 7.40741443e-04 2.60883891e-02 -1.62497797e-01 9.39108633e-02 -2.32157260e-01 4.25370961e-03 3.50913890e-01 2.54999266e-01 -2.02126492e-02 -1.11249801e-01 -2.65402658e-01 1.51455320e-01 -8.81522177e-02 5.83949634e-01 2.53778801e-02 6.87108397e-02 -9.03803396e-02 -1.38574806e-01 1.91512088e-01 4.95444983e-01 1.95601838e-01 -2.83060374e-01 9.48042620e-02 1.72644893e-01 4.18111579e-01 4.01002273e-01 -5.39645591e-02 2.50268373e-01 2.74000356e-02 2.52172863e-01 -1.08445858e-02 7.51022716e-02 -3.82219410e-01 -4.70944996e-01 -3.19074480e-01 -7.69470840e-01 3.01845092e-01 1.51141273e+00 2.35840231e-01 -7.89549535e-02 5.58619058e-01 4.82355026e-01 -2.30482334e-01 1.66987664e-01 2.10321666e+00 4.36405035e-01 2.22144217e-01 -5.07418326e-01 3.41378608e-01 3.59809781e-01 6.00348151e-01 4.59150155e-01 1.00553524e+00 -8.11067315e-01 4.10610994e-01 6.52367380e-02 -1.09422292e-01 -2.12542687e-01 4.32633952e-01 -3.44611801e-01 3.74981006e-02 -2.78140419e-01 3.90870887e-01 1.24779728e-02 8.67230181e-02 2.92398290e-01 4.89228227e-01 5.66615808e-01 2.00028101e-01 -2.65631967e-01 1.73110780e-02 1.92922891e-01 6.62456209e-02 1.09340165e-01 -1.11744617e-01 1.57506929e-01 1.70017359e-01 1.10304405e-01 -3.29875835e-02]
Not sure what to make of these values? The values indicating quandrant location: 1 HH, 2 LH, 3 LL, 4 HL hardly change though, as can be seen comparing loop_local_moran_I_KNN.q .
with warnings.catch_warnings(record=True):
print("Results for nightlight_900 with k equal..")
for keigh in (4,5,8,10):
loop_local_moran_I_KNN = esda.moran.Moran_Local( dataset_gdf['nightlight_900'],
KNN.from_dataframe( dataset_gdf,
k = keigh
)
)
print(keigh, ":", loop_local_moran_I_KNN.q)
Results for nightlight_900 with k equal.. 4 : [2 2 1 1 1 1 1 1 3 1 1 1 2 1 1 1 1 2 2 1 1 1 1 1 2 3 4 2 1 1 2 1 4 1 3 1 1 1 1 1 1 1 3 1 3 1 1 4 4 4 2 2 2 4 4 4 3 3 2 2 1 1 2 4 2 3 3 2 4 3 3 2 3 3 3 3 3 3 2 4 3 3 3 2 4 1 2 1 1 1 4 1 2 2 1 1 2 1 1 1 2 3 2 3 2 1 2 1 1 2 4 2 1 1 1 1 1 4 2 2 2 2 1 1 2 4 3 3 3 3 3 3 3 2 1 3 1 4 3 1 3 2 2 4 4 3 3 4 3 2 2 3 4 4 3 4 3 1 3 3 3 4 2 1 2 2 3 3 3 2 3 1 1 1 3 1 1 1 1 1 4 3 1 4 3 1 3 2 1 1 2 2 3 1 1 4 2 3 4 4 3 4 2 3 2 3 4 4 3 4 1 3 1 2 2 1 1 3 3 1 2 1 2 1 2 1 1 3 3 2 3 2 3 3 3 3 4 3 1 1 1 1 1 4 2 4 2 1 2 1 3 3 3 4 2 4 4 4 3 2 3 3 3 4 2 3 4 4 3 2 2 3 2 1 1 2 4 3 1 1 1 3 3 3 1 1 4 1 1 2 1 1 1 1 1 2 2 2 4 4 4 4 3 2 3 3 3 3 3 3 3 3 3 2 2 3 1 3 3 3 3 3 3 4 3 3 2 3 3 3 4 4 4 1 3 1 1 1 1 1 2 4 1 2 1 4 3 2 3 3 4 3 3 2 2 3 3 3 3 3 4 3 2 2 1 1 1 4 3 1 1 1 3 3 2 3 2 2 3 2 3 3 2 4 4 4 2 2 4 1 2 1 4 3 3 4 4 3 2 3 2 3 2 3 1 2 1 4 4 3 3 4 2 3 3 4 3 3 3 3 3 3 3 3 4 2 3 3 3 3 3 4 4 4 4 2 2 4 2 1 1 3 4 1 1 2 1 1 3 3 2 1 1 1 3 1 2 3 1 2 2 2 4 3 4 3 3 3 3 3 3 3 4 3 3 3 3 4 2 3 3 4] 5 : [2 2 1 1 1 1 1 1 2 1 1 1 2 1 1 1 1 2 2 1 4 4 1 1 2 3 1 2 1 1 2 1 1 1 2 1 1 1 1 1 1 1 3 1 2 1 1 4 4 4 2 3 2 4 1 4 3 3 2 2 1 1 2 4 2 3 2 3 4 3 3 2 2 3 3 3 3 3 2 4 3 2 3 2 4 1 3 1 1 1 1 1 2 2 1 1 2 1 1 1 2 3 2 3 2 1 2 1 4 2 4 2 1 1 1 1 1 1 2 2 2 2 1 4 2 4 3 3 3 3 3 3 3 2 1 3 1 4 3 1 3 2 2 4 4 3 3 4 3 2 2 3 4 4 3 4 3 1 3 3 3 4 2 1 2 3 3 3 3 2 3 1 1 1 3 1 1 1 1 1 4 3 1 4 3 1 3 2 1 1 2 2 3 1 1 4 2 3 1 4 3 4 2 3 2 3 4 4 3 4 1 3 1 2 2 1 1 3 3 1 2 1 2 1 2 1 1 3 3 2 3 3 3 3 3 3 4 3 1 1 1 1 1 4 3 4 2 1 2 1 3 3 3 1 2 4 4 4 2 2 2 3 3 4 2 3 4 4 2 2 2 3 2 1 1 2 4 3 1 1 1 3 3 3 1 1 4 1 1 2 1 4 1 1 1 3 2 2 4 4 4 4 3 2 3 3 3 3 3 3 3 3 3 2 2 3 1 3 3 3 3 3 3 4 3 3 2 3 3 3 4 4 4 1 3 1 1 1 1 1 2 4 1 2 1 4 3 3 3 3 1 3 3 2 2 3 2 3 3 3 4 3 2 2 1 1 1 1 3 1 4 1 3 3 2 2 2 2 3 2 3 3 2 4 4 4 2 2 4 4 3 4 4 3 3 4 4 3 2 3 2 3 3 3 1 2 1 4 1 3 3 4 2 2 3 4 3 3 3 3 3 3 3 3 4 3 3 3 3 3 3 4 4 4 4 2 2 4 2 1 1 3 4 1 1 2 1 1 3 3 2 1 1 1 3 1 2 3 1 2 2 2 4 3 4 3 3 3 3 3 3 3 4 3 3 3 3 4 3 3 3 4] 8 : [2 2 1 1 1 1 1 1 2 1 1 1 2 1 1 1 1 2 2 1 4 4 1 1 2 2 1 2 1 4 2 1 1 1 2 1 1 1 1 1 1 1 2 1 2 1 1 4 4 4 2 2 2 1 1 1 3 3 2 2 4 4 3 4 3 3 3 3 4 3 3 3 3 3 3 2 3 2 2 4 3 2 3 2 4 1 3 1 1 1 4 1 2 2 1 1 2 1 1 1 2 3 2 3 2 1 2 1 1 2 4 2 1 1 1 1 1 1 2 2 2 2 1 4 2 4 3 3 3 3 3 3 3 2 4 3 4 4 3 4 3 2 2 4 4 2 3 4 3 2 3 3 4 4 3 4 3 1 3 3 3 4 3 4 3 3 3 3 3 2 3 1 1 1 3 1 1 1 1 1 4 3 1 4 3 1 3 2 1 1 2 2 3 1 1 4 2 3 1 4 3 4 2 2 2 2 1 1 3 4 1 2 1 2 2 1 1 3 3 1 3 1 2 1 2 1 1 3 3 2 3 3 3 3 3 3 4 3 1 1 1 1 1 1 2 1 2 1 2 1 3 3 3 4 3 4 4 4 2 3 2 3 3 4 2 3 4 4 2 3 2 3 2 1 1 2 4 3 1 1 1 3 3 3 1 1 4 1 1 2 1 4 1 1 1 3 2 2 4 1 4 4 3 2 3 3 3 3 3 3 3 3 2 2 2 3 4 3 2 3 3 3 3 4 3 3 2 3 3 3 4 4 4 1 3 1 1 1 1 1 2 4 4 2 4 4 3 3 2 2 4 3 2 2 2 3 3 3 3 3 1 3 2 2 1 1 1 4 3 4 4 4 3 3 2 3 2 2 3 2 3 3 2 4 4 4 2 3 4 4 3 4 4 3 3 4 1 3 3 3 2 3 3 3 1 2 1 4 1 3 3 4 2 2 3 4 3 3 3 2 2 3 3 3 4 3 3 3 3 2 3 1 1 4 1 2 2 4 2 1 1 3 4 1 1 2 1 1 3 3 2 1 1 1 3 1 2 3 1 2 2 3 4 3 4 3 3 3 3 3 3 3 4 3 3 3 3 4 3 3 3 4] 10 : [2 2 1 1 1 1 1 1 2 1 1 1 2 1 1 1 1 2 2 1 1 4 1 1 2 2 1 2 1 1 2 1 1 1 2 1 1 1 1 1 1 1 2 1 2 1 1 1 1 1 2 2 2 1 1 4 2 3 2 2 4 4 3 4 3 3 3 3 4 3 3 3 3 3 3 3 3 2 2 4 2 2 3 2 4 1 3 1 1 1 4 1 2 2 1 1 2 1 1 1 2 2 2 3 3 1 2 1 1 2 4 2 4 1 1 1 1 1 3 2 3 2 1 4 2 1 3 2 3 2 3 3 3 2 4 3 4 4 3 4 3 2 3 4 4 3 3 4 3 3 2 3 4 4 3 4 3 1 3 3 3 4 3 1 2 2 3 3 2 2 3 1 1 1 3 1 1 1 1 1 4 3 1 4 3 1 2 2 1 1 2 2 3 1 1 4 2 3 1 4 3 4 2 2 2 2 1 1 3 1 1 2 1 2 2 1 1 3 3 1 2 4 2 1 2 1 1 3 3 2 3 2 2 3 2 3 4 2 1 1 1 1 1 1 2 1 2 1 2 1 3 3 3 4 3 4 4 4 2 3 2 3 3 4 2 2 4 4 2 3 2 3 2 1 1 2 4 3 1 1 1 3 3 3 1 1 4 1 1 2 1 4 1 1 1 3 2 2 4 1 1 4 3 2 2 3 3 3 2 3 3 3 3 2 3 3 4 3 2 3 3 3 3 4 3 3 3 3 3 3 4 4 4 4 3 1 1 1 1 1 2 4 4 2 4 4 3 3 2 3 4 3 3 2 2 3 3 3 3 3 1 3 2 2 1 1 1 4 3 4 4 4 3 3 2 2 3 2 2 2 3 2 2 1 1 1 2 3 4 4 3 4 4 3 3 4 1 3 3 3 2 3 3 3 1 2 1 4 1 3 3 4 2 2 3 4 3 3 3 2 2 3 3 3 4 3 3 3 3 2 3 1 1 4 1 2 2 4 2 1 1 3 4 1 1 2 1 1 3 3 2 1 1 1 3 1 2 3 1 2 2 3 4 3 4 3 3 3 3 3 3 3 4 3 3 3 3 4 3 3 3 4]
Dietmar Schreyer, Bayreuth, 12.12.2021
File "C:\Users\Dietmar\AppData\Local\Temp/ipykernel_11204/535485915.py", line 1 Dietmar Schreyer, Bayreuth, 12.12.2021 ^ SyntaxError: invalid syntax
# :-)